import { createSlice } from '@reduxjs/toolkit'

export const counterSlice = createSlice({
    name: 'counter',
    initialState: {
        show: false
    },
    reducers: {
        display: state => {

            state.show = true
        },
        hide: state => {
            console.log(state, "[[[[[[[");
            state.show = false
        },
        Toggle: state => {
            console.log(state, "[[[[[[[");
            state.show = !state.show
        }

    }
})
export const { display, hide, Toggle } = counterSlice.actions
export default counterSlice.reducer